package edu.uvic.TabViz.framework.WiFi;

import java.io.Serializable;

public class Data implements Serializable {
	/**
	 * 
	 */
	private static final long serialVersionUID = -1076781161841342991L;
	public Object  data;
	public int 	   type;

	/**
	 * --- Constants values can be passed in in type to the Server ---
	 */
	public static final int Syncronization     = 10;
	public static final int Replication        = 11;
	public static final int Grab               = 12;
	public static final int Release            = 14;
	public static final int Share              = 15;
	
	public static final int Touch       	   = 20;
	
	public static final int REQUEST            = 31;
	public static final int RESPONSE           = 32;

	public Data()
	{
		//data = new Object();
	} 
	/**
	 * Initialize the data structure
	 */
	public Data(Object o, int type)
	{
		data = o;
		this.type = type;
	} 
	/**
	 * Copy over it contents 
	 */
	public boolean copy( Data tSrc )
	{
		if (tSrc!= null){
			this.data        = tSrc.data;
			this.type        = tSrc.type;
			return true;
		}
		else 
			return false;
	}
}
